home *** CD-ROM | disk | FTP | other *** search
/ Disc to the Future 2 / Disc to the Future Part II Programmer's Reference (Wayzata Technology)(6013)(1992).bin / MAC / THINKC / 5 / DINKDEMO / DINKCLAS / DEVENTHA.H < prev    next >
Text File  |  1992-07-08  |  1KB  |  72 lines

  1. /*
  2.     File:        DEventHandler.h
  3.  
  4.     Written by:    Mark Gross
  5.  
  6.     Copyright:    ⌐ 1992 by Applied Technical Software, all rights reserved.
  7.     Use at your own risk.
  8.  
  9. */
  10.  
  11.  
  12. #ifndef __DEVENTHANDLER__
  13. #define __DEVENTHANDLER__
  14.  
  15. #include "DObject.h"
  16.  
  17. class DApplication; // forward declaration of application
  18.  
  19.  
  20. class DEventHandler : public DObject
  21. {
  22. public:
  23.  
  24.     static DApplication *gApplication;
  25.  
  26.                                        
  27.     static Boolean gPassItOn;
  28.  
  29.     
  30.     DEventHandler *fNextHandler;
  31.  
  32.         
  33.     Boolean fAlive;
  34.  
  35.     
  36.     DEventHandler(void);
  37.         // Instal itself into the event handler list of the
  38.         // application
  39.         
  40.     ~DEventHandler(void);    // empty destructor
  41.  
  42.     
  43.     virtual void KillMeNext(void);
  44.  
  45.                 
  46.     virtual void HandleNullEvent(EventRecord *theEvent);
  47.     virtual void HandleActivateEvt(EventRecord *theEvent);
  48.  
  49.     virtual void HandleAutoKey(EventRecord *theEvent);
  50.     virtual void HandleKeyDown(EventRecord *theEvent);                    
  51.  
  52.     virtual void HandleDiskEvt(EventRecord *theEvent);
  53.  
  54.     virtual void HandleHighLevelEvent(EventRecord *theEvent);
  55.     virtual void HandleOSEvent(EventRecord *theEvent);
  56.     virtual void HandleUpdateEvt(EventRecord *theEvent);
  57.     
  58.     virtual void HandleMouseDown(EventRecord *theEvent, 
  59.                             short thePart, WindowPtr theWindow);
  60.  
  61.  
  62.     virtual void HandleMenuChoice(short menuID, short menuItem);
  63.             
  64.     void EnableMenuItem(MenuHandle menu, short item, Boolean enable);
  65.     
  66.     virtual void SetUpMenues(void);
  67.  
  68. }; // end of Class declaration
  69.  
  70. #endif __DEVENTHANDLER__
  71.  
  72.